#include "head.h"

int addtoEpoll(int epoll_fd, int socket_fd){
    struct epoll_event event;
    bzero(&event,sizeof(event));

    event.data.fd = socket_fd;
    event.events = EPOLLIN;

    epoll_ctl(epoll_fd,EPOLL_CTL_ADD,socket_fd,&event);
    return 0;
} 

int delfromEpoll(int epoll_fd, int socket_fd){
    epoll_ctl(epoll_fd,EPOLL_CTL_DEL,socket_fd,NULL);
    return 0;
}
